import React from 'react'
// Route组件的作用:帮助我们快速定义前端路由规则
import { Route, Link } from 'react-router-dom'
import Home from './pages/Home'
import About from './pages/About'
export default function App() {
  return (
    <div>
      App
      <hr />
      <Link to="/home">首页</Link>
      <Link to="/about">关于</Link>
      {/* <Home></Home>
      <About></About> */}
      <hr />
      {/* 注意: 定义Home组件前端路由规则的代码,写在哪里,Home组件未来就渲染在哪里 */}
      <Route path="/home" component={Home}></Route>
      <Route path="/about" component={About}></Route>
      <hr />
    </div>
  )
}
